package com.zhk.ScriptManagement.mapper;

import com.zhk.ScriptManagement.entity.ScriptType;
import com.zhk.ScriptManagement.entity.vo.ScriptInfoVo;
import com.zhk.ScriptManagement.entity.ScriptRelationType;
import com.zhk.ScriptManagement.entity.vo.ScriptVo;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import org.springframework.stereotype.Component;

import java.util.List;

/**
 * @Author: zhouhongkun
 * @Description: 剧本service实现类
 * @Date: 2021/4/5 11:56
 */
@Component
@Mapper
public interface ScriptMapper {


    List<ScriptVo> getFuzzyScripts(@Param("scriptName") String scriptName,@Param("scriptTypeId") Integer scriptTypeId,@Param("scriptNum") Integer scriptNum,@Param("userId") Integer userId);

    ScriptVo getScriptByScriptId(@Param("scriptId") Integer scriptId);

    int updateCurrentScript(@Param("script") ScriptVo script);

    int addScript(@Param("scriptInfoVo") ScriptInfoVo scriptInfoVo);

    int addCurrentScript(@Param("scriptInfoVo") ScriptInfoVo scriptInfoVo);

    int addScriptTypes(@Param("scriptType") ScriptRelationType scriptType);

    int updateScript(@Param("scriptInfoVo") ScriptInfoVo scriptInfoVo);

    int deleteCurrentScript(@Param("scriptId") Integer scriptId);

    int deleteScriptType(@Param("scriptId") Integer scriptId);

    int addScriptType(@Param("scriptType") ScriptType scriptType);

    int updateScriptType(@Param("scriptType") ScriptType scriptType);

    List<ScriptType> getScriptTypes();
}
